    <div class="row">
        <div class="large-8 columns" style="left: 181px;">
            <h1>
                <small>
                    Editar Usuários  
                </small>
            </h1>
        </div>   
    </div>
<?php 
//var_dump(get_user());exit;
?>
    <form method="post" action="<?php echo base_url('index.php/usuario/editar_usuario') ?>">

        <div class="row">
            <div class="small-8 columns" style="left: 181px">

                <input type="hidden" name="rf_id" value="<?php echo $user->rf_id ?>" />
                Nome:<br />
                <input type="text" class="validate[required]" value="<?php echo $user->rf_nome ?>" name="rf_nome" />
                Login:<br />
                <input type="text" class="validate[required]" value="<?php echo $user->rf_login ?>" name="rf_login" />
                <br />
                E-mail:<br />
                <input type="text" class="validate[required, custom[email]]" value="<?php echo $user->rf_email ?>" name="rf_email" />
                <br />
                Nova Senha:<br />
                <input type="password" name="senha" /> 
                <div style="margin:7px 0;" class="alert alert-info"><i>Dica de Senha. No minimo 8 caracteres, não pode ser sequêncial.</i></div>
            </div>
        </div>
        <div class="row">
            <div class="large-8 columns" style="left: 181px;">
                <h1>
                    Permissões de Usuários  </h1>
            </div>   
        </div>
        <div class="row">
            <div class="small-8 columns" style="left: 181px">
                Permissão:<br />
                <div style="margin-bottom:15px;">
                    <?php
                    $modulos = get_modulos();
                    foreach ($modulos as $k => $m) {
                        ?>
                        <div style="padding:10px 0; width:400px; border-bottom:1px solid #f0f0f0">
                            <strong><?php echo $m['name'] ?></strong><br />
                            <?php if (isset($m['option'][0]) && $m['option'][0] == 'combo') { ?>
                                <input type="checkbox" <?php echo permissao($k, 'visualizar', $user) ? 'checked' : ''; ?> name="permissao[<?php echo $k ?>][visualizar]" value="1" /> Visualizar
                                <input type="checkbox" <?php echo permissao($k, 'adicionar', $user) ? 'checked' : ''; ?> name="permissao[<?php echo $k ?>][adicionar]" value="1" /> Adicionar
                                <input type="checkbox" <?php echo permissao($k, 'editar', $user) ? 'checked' : ''; ?> name="permissao[<?php echo $k ?>][editar]" value="1" /> Editar
                                <input type="checkbox" <?php echo permissao($k, 'excluir', $user) ? 'checked' : ''; ?> name="permissao[<?php echo $k ?>][excluir]" value="1" /> Excluir
                                <?php
                            } else {
                                foreach ($m['option'] as $op) {
                                    ?>
                                    <input type="checkbox" <?php echo permissao($k, $op, $user) ? 'checked' : ''; ?> name="permissao[<?php echo $k ?>][<?php echo $op ?>]" value="1" /> <?php echo $op ?>
                                <?php }
                            } ?>
                        </div>  
<?php } ?>
                </div>


                <input type="submit" class="btn" value="Salvar Usuário" />
                <a class="btn" href="<?php echo base_url('index.php/usuario') ?>">Cancelar</a>
            </div>
        </div>
    </form>